package com.wisemoresystem.seal.action.seal.recieve;

import java.util.List;
import java.util.Map;

import org.ne.framework.data.util.ChkTools;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.context.annotation.Scope;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.servlet.ModelAndView;

import com.wisemoresystem.seal.base.action.ProjBaseAction;
import com.wisemoresystem.seal.service.SealRecieveService;
import com.wisemoresystem.seal.util.DateTools;
import com.wisemoresystem.seal.web.WebTools;

/**
 * 印章下发验证码查询
 * 
 * @author hxj
 */
@Controller("ixSealRecieveIndentifyCode")
@Scope("prototype")
@RequestMapping("/ix/seal/recieve/identify")
public class SealDistributeRecieveIndentifyCodeAction extends ProjBaseAction {

	@Autowired
	private SealRecieveService service;
	/**
	 * 印章下发验证码列表
	 * @param srh_name
	 * @return
	 */
	@RequestMapping("/list")
	public ModelAndView list(String srh_name) {
		if (ChkTools.isNull(srh_name))
			srh_name = DateTools.getToday();

		List<Map<String, Object>> list = service.selectIndentifyCodeList(
				WebTools.getCurrentBankId(), srh_name);

		ModelAndView mv = new ModelAndView("/jsp/seal/recieve/identify/list");
		mv.addObject("list", list);
		mv.addObject("srh_name", srh_name);
		return mv;
	}
}
